package com.hongawen.poi.controller;

import com.hongawen.poi.pojo.Company;
import com.hongawen.poi.service.ImageService;
import com.hongawen.poi.service.MultipleService;
import com.hongawen.poi.service.StudentService;
import com.hongawen.poi.service.TreeService;
import lombok.AllArgsConstructor;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * @author hongawen
 * @version 1.0.0
 * @date 2022年03月30日 14:31
 */
@Controller
@AllArgsConstructor
public class ExcelController {

    private final StudentService studentService;

    private final MultipleService multipleService;

    private final ImageService imageService;

    @GetMapping("exportStudent")
    @ResponseBody
    public void exportStudent() {
        studentService.exportStudent();
    }

    @GetMapping("exportStudentCSV")
    @ResponseBody
    public void exportStudentCSV() {
        studentService.exportStudentCSV();
    }

    @GetMapping("exportTeacher")
    @ResponseBody
    public void exportTeacher() {
        studentService.exportTeacher();
    }

    @GetMapping("exportCourse")
    @ResponseBody
    public void exportCourse() {
        studentService.exportCourse();
    }


    @GetMapping("exportMultiple")
    @ResponseBody
    public void exportMultiple() {
        multipleService.exportMultiple();
    }

    @GetMapping("exportCompany")
    @ResponseBody
    public void exportCompany() {
        imageService.exportCompany();
    }



}
